<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>函数return函数</title>
</head>
<body>
<script>
    function Foo() {
        var ww=0;
        return function () {
            console.log(ww++);
        }
    }
    var f1 = Foo(),f2=Foo();
    f1();
    f1();
    f2();
</script>
</body>
</html>